This is the replication folder for the BJPS paper titled, "Field Experiments Invoking Gloating Villains to Increase Voter Participation: Anger, Anticipated Emotions, and Voting Turnout."

This version: 2025 March 03.

*************************************************

To reproduce the analysis, download the contents into a folder and then click "Replication.Rproj" to automatically set the working directory to this folder. You will then need to specify the output path in 02_analysis.R and create an output director.

*************************************************

There are 13 items files in this replication archive.

1. README.MD: This file.
2. Replication.Rproj: The R Project file that sets the local working directory.
3. 01_cleaning.R: R script, described below
4. 02_analysis.R: R script, described below
5. make_table.R: R script, described below
6. experiment1_cleaned.csv: The cleaned .csv file for experiment 1, produced by 01_cleaning.R
7. experiment2_cleaned.csv: The cleaned .csv file for experiment 2, produced by 01_cleaning.R
8. experimentA_cleaned.csv: The cleaned .csv file for experiment A, produced by 01_cleaning.R
9. experimentB_cleaned.csv: The cleaned .csv file for experiment B, produced by 01_cleaning.R
10. experimentC_cleaned.csv: The cleaned .csv file for experiment C, produced by 01_cleaning.R
11. experimentCresp_cleaned.csv: The cleaned respondent demographic .csv file for experiment C, produced by 01_cleaning.R
12 Table_Heroes_By_Party.csv: The raw data on stated heroes by respondent partisanship
13 Table_Villains_By_Party.csv: The raw data on stated villains by respondent partisanship

*************************************************

Details on R scripts

There are three R scripts:
01_cleaning.R
02_analysis.R
make_table.R

01_wrangling.R is the cleaning script that loads the raw data (not included in this archive) and saves the respective cleaned .csv analysis files.

NOTE: This script is present to make it clear how we cleaned and preprocessed the data. You will not be able to run 01_cleaning.R because we have not uploaded the raw identifiable data.

02_analysis.R loads the cleaned datasets and produces the tables in the main paper and the supplementary materials. You must uncomment and define the "save_path" variable on line 22 for this code to run:
# save_path <- "C:/PublicReplicationFile/output"

Finally, make_table.R is a function script containing two table wrapper functions:

"make_texreg.R" is a wrapper function for producing Latex-ready regression tables.
"make_kable.R" is a wrapper function for producing Latex-ready general tables.

